<div>
  <span ng-show="items.length == 0">
    <em>None</em>
  </span>

  <ol start="1">
    <li ng-repeat="item in localItems">
      <span ng-hide="activeItem == $index">
        <span ng-hide="largeInput">
          <[item.label]>
        </span>
        <span ng-show="largeInput">
          <textarea disabled="true"><[item.label]></textarea>
          <br>
        </span>

        (<a ng-click="openItemEditor($index)">Edit</a> | <a ng-click="deleteItem($index)">Delete</a>)
      </span>

      <span ng-show="activeItem == $index">
        <input ng-hide="largeInput" type="text" ng-model="item.label">
        <textarea ng-show="largeInput" ng-model="item.label">
        </textarea>
        <button type="button" ng-click="replaceItem($index, item.label)">Save</button>
      </span>
    </li>
  </ol>

  <input ng-hide="largeInput" type="text" ng-model="newItem" placeholder="Add New List Item">
  <textarea ng-show="largeInput" ng-model="newItem" placeholder="Add New List Item"></textarea>
  <button type="button" ng-click="addItem(newItem)">Add List Element</button>
</div>
